package com.ruoyi.store.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.store.mapper.TotalMoneyMapper;
import com.ruoyi.store.domain.TotalMoney;
import com.ruoyi.store.service.ITotalMoneyService;
import com.ruoyi.common.core.text.Convert;

/**
 * 汇总报Service业务层处理
 * 
 * @author ruoyi
 * @date 2023-05-02
 */
@Service
public class TotalMoneyServiceImpl implements ITotalMoneyService 
{
    @Autowired
    private TotalMoneyMapper totalMoneyMapper;

    /**
     * 查询汇总报
     * 
     * @param id 汇总报主键
     * @return 汇总报
     */
    @Override
    public TotalMoney selectTotalMoneyById(Long id)
    {
        return totalMoneyMapper.selectTotalMoneyById(id);
    }

    /**
     * 查询汇总报列表
     * 
     * @param totalMoney 汇总报
     * @return 汇总报
     */
    @Override
    public List<TotalMoney> selectTotalMoneyList(TotalMoney totalMoney)
    {
        return totalMoneyMapper.selectTotalMoneyList(totalMoney);
    }

    /**
     * 新增汇总报
     * 
     * @param totalMoney 汇总报
     * @return 结果
     */
    @Override
    public int insertTotalMoney(TotalMoney totalMoney)
    {
        return totalMoneyMapper.insertTotalMoney(totalMoney);
    }

    /**
     * 修改汇总报
     * 
     * @param totalMoney 汇总报
     * @return 结果
     */
    @Override
    public int updateTotalMoney(TotalMoney totalMoney)
    {
        return totalMoneyMapper.updateTotalMoney(totalMoney);
    }

    /**
     * 批量删除汇总报
     * 
     * @param ids 需要删除的汇总报主键
     * @return 结果
     */
    @Override
    public int deleteTotalMoneyByIds(String ids)
    {
        return totalMoneyMapper.deleteTotalMoneyByIds(Convert.toStrArray(ids));
    }

    /**
     * 删除汇总报信息
     * 
     * @param id 汇总报主键
     * @return 结果
     */
    @Override
    public int deleteTotalMoneyById(Long id)
    {
        return totalMoneyMapper.deleteTotalMoneyById(id);
    }
}
